!/bin/bash

# ------------------------------ Procedures ----------------------------
readFile ()
{
FILE=$1
if [ -f $FILE ]; then
  cat $FILE
else
  printf "-"
fi
}

# ------------------------------- Main --------------------------------
                                                                                                                             

if [ "$1" = "" ]; then
  ACTION=none
else
  ACTION=$1
fi
if [ "$2" = "" ]; then
  PARAM1=none
else
  PARAM1=$2
fi
if [ "$3" = "" ]; then
  PARAM2=none
else
  PARAM2=$3
fi

echo "
      <A HREF=$SCRIPT_NAME?test+get-info>Get Info</A> |
      <A HREF=$SCRIPT_NAME?test+discover>Discover</A> |
      <A HREF=$SCRIPT_NAME?test+unpack-tunix>Unpack Tunix configs</A> |
      </TD></TR></TABLE><CENTER>
     "
case $ACTION in
  (discover)       $SIM_SUDO $SIM_STARTER discover $SIM_MANDOMAIN verbose ;;
  (get-info)       $SIM_SUDO $SIM_STARTER get-info $SIM_MANDOMAIN verbose ;;
  (unpack-tunix)   $SIM_SUDO $SIM_STARTER $ACTION $SIM_MANDOMAIN verbose ;;
  (*) echo "Please select an action from the menu......" ;;
															    esac
